package com.company.design.create.factory.abstracts;

/**
 * @author yingfing
 * @create 2020--09--26 10:52
 * @describe
 */
public class FactoryProducer {
    public static AbstractFactory getFactory(String brand) {
        if ("microsoft".equalsIgnoreCase(brand)) {
            return new MicrosoftFactory();
        } else if ("logic".equalsIgnoreCase(brand)) {
            return new LogicFactory();
        } else {
            System.out.println("该品牌还没有创建!");
            return null;
        }
    }
}
